import random;
r = random;
d = r.randint(1, 20);
T = r.randint(1, 20);
print(str(d) + " " + str(T));
for i in range(T):
	x1 = r.randint(1, 20);
	y1 = r.randint(1, 20);
	x2 = r.randint(x1, 20);
	y2 = r.randint(y1, 20);
	print(str(x1) + " " + str(y1) + " " + str(x2) + " " + str(y2));
